module.exports = {
  /*
  ** Headers of the page
  */
  head: {
    title: 'nuxt_hero',
    script: [  
      //在启动页嵌入静态js
      { src: '/js/exmobi.js' }  
    ],  
    meta: [
      { charset: 'utf-8' },
      { name: 'viewport', content: 'width=device-width, initial-scale=1' },
      { hid: 'description', name: 'description', content: 'nuxt test' }
    ],
    // link: [
    //   { rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }
    // ]
  },
  /*
  ** Customize the progress bar color
  */
  loading: {
    color: 'blue'
  },
  css:[
    {src:'element-ui/lib/theme-chalk/index.css'},
    '~assets/iconfont/iconfont.css',
    '~assets/transletion/page-transletion.css',
  ],
  /*
  ** Build configuration
  */
  build: {
    /*
    ** Run ESLint on save
    */
    extend (config, { isDev, isClient }) {
      if (isDev && isClient) {
        config.module.rules.push({
          enforce: 'pre',
          test: /\.(js|vue)$/,
          loader: 'eslint-loader',
          exclude: /(node_modules)/
        })
      }
    },
    vendor:['element-ui','mint-ui','vue-quill-editor','axios']
  },
  plugins: [
    { src: '~plugins/element-ui', ssr: true },
    { src: '~plugins/mint-ui', ssr: true },
    { src: '~plugins/vue-quill-editor', ssr: false }
    // ,{ src: '~plugins/vue-html5-editor', ssr: true }
  ],
  router: {
    base:"/",
    mode: 'hash'
  },
  //axios代理访问本机的第三方api
  modules: [ 
    '@nuxtjs/axios',
    '@nuxtjs/proxy'
  ], 
  // axios: { prefix: '/api/', proxy: true },
  // proxy: { 
  //   '/api/': { target: 'http://localhost:8080/BLBE',
  //              pathRewrite: {'^/api/': ''} 
  //            } 
  // }

}
